package com.ywk.base.common.office.excel.exportExcel;

import com.ywk.base.common.office.excel.Anno;
import org.apache.poi.ss.usermodel.CellStyle;
import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.xssf.streaming.SXSSFWorkbook;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

/**
 * 记录excel各个参数的实体类
 * @author binzec
 */
public class ExcelBean {

	/**
	 * 工作薄对象
	 */
	private SXSSFWorkbook wb;
	
	/**
	 * 工作表对象
	 */
	private Sheet sheet;
	
	/**
	 * 样式列表
	 */
	private Map<String, CellStyle> styles;
	
	/**
	 * 当前行号（从第一行开始 ）
	 */
	private int rownum = 0;
	
	/**
	 * 实体类字段属性集合
	 */
	private List<Anno> annotationList = new ArrayList<Anno>();

	public ExcelBean(SXSSFWorkbook wb, Sheet sheet, Map<String, CellStyle> styles, int rownum, List<Anno> annotationList) {
		super();
		this.wb = wb;
		this.sheet = sheet;
		this.styles = styles;
		this.rownum = rownum;
		this.annotationList = annotationList;
	}

	public SXSSFWorkbook getWb() {
		return wb;
	}

	public void setWb(SXSSFWorkbook wb) {
		this.wb = wb;
	}

	public Sheet getSheet() {
		return sheet;
	}

	public void setSheet(Sheet sheet) {
		this.sheet = sheet;
	}

	public Map<String, CellStyle> getStyles() {
		return styles;
	}

	public void setStyles(Map<String, CellStyle> styles) {
		this.styles = styles;
	}

	public List<Anno> getAnnotationList() {
		return annotationList;
	}

	public void setAnnotationList(List<Anno> annotationList) {
		this.annotationList = annotationList;
	}

	public int getRownum() {
		return rownum;
	}

	public void setRownum(int rownum) {
		this.rownum = rownum;
	}
	
}
